﻿.taskChecklistBox {
  .taskChecklist {
    border: 1px solid #e0e0e0;
    background: #fff;
    padding: 10px 0 10px;
    margin-top: 10px;
    border-radius: 5px;
    user-select: none;
  }
  .taskChecklistHead {
    padding-right: 24px;
    padding-left: 45px;
    position: relative;
    .icon-task-list {
      position: absolute;
      top: 6px;
      font-size: 16px;
      color: #8f9093;
      left: 12px;
    }
    .taskChecklistName {
      margin-right: 50px;
      padding: 6px 0;
      line-height: 20px;
      word-break: break-all;
      .taskChecklistCount {
        color: #9e9e9e;
        margin-left: 5px;
      }
    }
    .icon-moreop {
      position: absolute;
      top: 8px;
      right: 46px;
      font-size: 16px;
      &:not(:hover) {
        color: #9e9e9e !important;
      }
    }
    .taskDetailFold {
      position: absolute;
      top: 8px;
      right: 22px;
      .icon-arrow-down-border,
      .icon-arrow-up-border {
        font-size: 16px;
        &:not(:hover) {
          color: #9e9e9e !important;
        }
      }
    }
    textarea {
      width: 100%;
      padding: 5px 10px;
      line-height: 20px;
      height: 20px;
      border: 1px solid #ccc;
      box-sizing: border-box;
      border-radius: 3px;
      resize: none;
      vertical-align: top;
      font-size: 14px;
      word-break: break-all;
    }
  }

  .checklistOperator {
    position: absolute;
    right: 15px;
    top: 30px;
    background: #fff;
    z-index: 10;
    padding: 6px 0;
    li {
      height: 32px;
      line-height: 32px;
      padding: 0 15px;
      cursor: pointer;
      i {
        color: #9e9e9e;
        font-size: 16px;
        width: 30px;
        display: inline-block;
      }
      .icon-help {
        width: auto;
        font-size: 14px;
      }
      span[data-tip]:after {
        width: 200px;
        white-space: normal;
      }
      &:not(:hover) {
        background: #fff !important;
      }
      &:hover,
      &:hover i {
        color: #fff;
      }
    }
  }

  .taskChecklistPercent {
    padding-right: 24px;
    padding-left: 45px;
    position: relative;
    .taskChecklistPercentNum {
      position: absolute;
      top: -5px;
      color: #9e9e9e;
      left: 12px;
    }
    .percentBox {
      width: 100%;
      height: 8px;
      background: #dcdcdc;
      font-size: 0;
      border-radius: 8px;
    }
    .percentSize {
      height: 8px;
      font-size: 0;
      border-radius: 8px;
      background: #30af00;
    }
  }

  .taskChecklistItems {
    padding: 0 24px 0 45px;
    .emptyItem {
      height: 15px;
      width: 100%;
      margin-bottom: -15px;
    }
  }

  .taskChecklistItem {
    margin-top: 6px;
    position: relative;
    &:hover,
    &.itemActive {
      background: #f6f6f6;
      .icon-moreop {
        display: inline-block;
        &:not(:hover) {
          color: #9e9e9e !important;
        }
      }
    }
    &.itemActiveBG {
      background: #f6f6f6;
    }
    .checklistItemStatus {
      color: #757575;
      display: inline-block;
      vertical-align: top;
      margin: 9px 12px 0 6px;
      height: 18px;
      &.icon-ok {
        color: #30af00;
      }
    }
    .checklistItemName {
      padding: 8px 28px 8px 0;
      line-height: 20px;
      word-break: break-all;
    }
    .checklistItemCompleted {
      text-decoration: line-through;
      color: #9e9e9e;
    }
    textarea {
      resize: none;
      border: none;
      padding: 8px 28px 8px 0;
      line-height: 20px;
      display: inline-block;
      vertical-align: top;
      height: 20px;
      background: #f6f6f6;
      word-break: break-all;
    }
    .icon-moreop {
      font-size: 16px;
      color: #9e9e9e;
      display: none;
      position: absolute;
      top: 10px;
      right: 0;
    }
    .checklistOperator {
      right: -5px;
    }
  }

  .taskChecklistAdd {
    margin: 6px 24px 0 45px;
    .checklistItemStatus {
      color: #9e9e9e;
      display: inline-block;
      vertical-align: top;
      margin: 10px 12px 0 6px;
    }
    textarea {
      resize: none;
      border: none;
      padding: 0 28px 0 0;
      line-height: 20px;
      display: inline-block;
      vertical-align: top;
      margin: 8px 0;
      height: 20px;
    }
  }

  .taskChecklistItemAdd {
    margin-left: 51px;
    margin-top: 6px;
    height: 36px;
    line-height: 36px;
    font-size: 13px;
    &:not(:hover) {
      color: #9e9e9e !important;
    }
    &:not(.Hidden) {
      display: inline-block;
    }
    i {
      font-size: 14px;
      margin-right: 10px;
    }
  }

  .taskDetailDragPreview {
    position: fixed;
    border: 0;
    cursor: grabbing;
    pointer-events: none;
    z-index: 100;
    border-radius: 5px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    & > * {
      pointer-events: none;
    }
    .taskChecklist,
    .taskChecklistItem {
      margin-top: 0;
      background: rgba(255, 255, 255, 0.9);
    }
    .taskChecklist .taskChecklistItem {
      margin-top: 6px;
      background: transparent;
    }
  }
}
